Apparatus and method for air-in-line detection

ABSTRACT

The concentration of air or other agents in a fluid delivery line is determined by monitoring agent signals and processing those agent signals along with information regarding the age of each agent signal. The processor determines a primary agent concentration value based on the received agent signal values, with the primary agent concentration value determined by giving greater weight to more recent agent signal values. Where the primary agent concentration value exceeds a primary threshold value, an alarm signal may be activated. The processor also may determine a secondary agent concentration value, which may be determined from the actual agent signal values instead of the weighted agent signal values. Where the secondary agent concentration value exceeds a secondary threshold value, an alarm signal may be activated.

This is a continuation of application Ser. No. 10/656,424, filed Sep. 5,2003, now U.S. Pat. No. 7,141,037, which is a continuation ofapplication Ser. No. 08/933,709, filed Sep. 19, 1997, now U.S. Pat. No.6,616,633. The contents of application Ser. Nos. 10/656,424 and08/933,709 are incorporated herein by reference.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The invention relates to fluid delivery systems. More particularly, thepresent invention relates to detecting air and other agents in a fluiddelivery system infusing fluid to a patient.

2. Description of Related Art

There are a variety of situations where fluid is infused to a patient.Applications of fluid delivery systems include (but are by no meanslimited to) intravenous infusion, intra-arterial infusion, infusion ofenteral solutions, infusion of medication to the epidural space, anddiagnostic infusion to determine vascular characteristics of thearterial, urinary, lymphatic, or cerebrospinal systems.

Fluid delivery systems for infusing fluid to a patient typically includea supply of the fluid to be administered, an infusion needle or cannula,an administration set connecting the fluid supply to the cannula, and aflow control device, such as a positive displacement infusion pump. Theadministration set typically comprises a length of flexible tubing. Thecannula is mounted at the distal end of the flexible tubing forinsertion into a patient's blood vessel or other body location todeliver the fluid infusate to the patient.

During an infusion procedure, various agents, the most typical of whichis air, can be introduced into the fluid delivery system by a number ofevents, including the fluid supply becoming drained of fluid. Becauseintroducing excessive air into the patient's blood system may createcomplications, it is desirable to detect the introduction of air intothe fluid delivery system before substantial amounts of air areintroduced into the patient. When substantial amounts of air aredetected in the fluid delivery system, fluid delivery can be terminateduntil a health care provider can correct the underlying problem, such asby refilling or replacing the fluid supply.

Sometimes, a temporary event, such as the accumulation of smallquantities of air from outgassing of air suspended in the solution, maycause a very few small air bubbles to enter the system. Where the amountof air is quite small, the patient may be able to safely absorb thesmall air amounts, so that stopping operation of the pump isunnecessary. Thus, it is desirable to not only detect the air in thefluid delivery system, but also to evaluate the amount of air present.

One technique for determining the amount of air in a fluid deliverysystem, such as a length of intravenous tubing, is through the use ofsensors such as light or ultrasonic sensors. In such a technique,electromagnetic energy, such as light, or sound energy, such as anultrasonic pulse, is passed through the intravenous tubing, and thesensor monitors variations in the received energy. Because air generallytransmits light and/or sound energy in a different fashion than dointravenous fluid solutions, due to different transmission propertiessuch as absorption and/or refractivity, monitoring variations in thelight's or sound's ability to pass through the solution can give agenerally accurate determination that air exists in the fluid line.

A more difficult problem is determining just how much air is in thefluid line, and how much will be delivered to the patient. For example,at a particular point in time, a sensor looking at just a very shortsection of the tubing may see only air in the line, with no intravenousfluid solution present. This may be the result of the fluid supply beingentirely empty, in which case the fluid delivery system should be shutdown. However, a single small air bubble may also cause the same sensorreading, and shutting down the fluid delivery system on account of asingle air bubble may be inappropriate.

A small amount of air may be of no consequence where no significantamounts of air are in the delivery system either upstream or downstreamof the sensor section. Where the small amount of air is part of acontinuous stream of small air bubbles in the tubing, however, the sumof the small bubbles may amount to a significant amount of air, so thatthe fluid supply system should be shut off pending correction of theunderlying problem.

A method of accounting for the limitations of monitoring just a shortsection of the tubing is to install several sensors along the length ofthe tubing, thereby monitoring a much longer section of tubing. Theaddition of multiple sensors and their associated electronics can,however, substantially add to the cost and complexity of the fluiddelivery system. Moreover, such use of multiple sensors may still notaccurately determine the amount of air in the line over long periods oftime or as large volumes of fluid pass therethrough.

A further method is to keep a running total of the air that passesthrough the tubing section. When the total air reaches a certainthreshold, the fluid delivery system can be shut down to awaitcorrection of the underlying problem by appropriate personnel. Such asimple running total may not, however, adequately reflect the actualability of the patient's system to safely absorb air.

Hence, those skilled in the art have recognized a need for a fluiddelivery monitoring system that can detect air in the fluid, but thatcan also take into account the total air over a period of time or in avolume of fluid, as well as to account for other factors, such as theability of the patient's body to safely absorb some air during fluidvolume infusion. The present invention satisfies these needs and others.

SUMMARY OF THE INVENTION

Briefly and in general terms, the present invention is directed to anapparatus and method for monitoring concentrations of air or otheragents, such as undesirable impurities, mixed into a fluid supplysystem. The invention has particular application in detecting air in afluid supply system.

The invention includes an agent sensor coupled to a fluid conduit forproviding signals in response to agents sensed in the fluid conduit. Aprocessor receives the agent signals from the agent sensor, determiningone or more weighted agent signal values by applying a weighting valueto one or more of the agent signals based on the volume delivered sinceeach agent signal was received, and determines an agent concentrationvalue from the weighted agent signal values. The processor may comparethe agent concentration value to an alarm threshold and, in response tothe agent concentration value exceeding the alarm threshold, provide analarm signal that activates an alarm.

The apparatus may further include a fluid control device, such as aperistaltic pump, acting on a section of the fluid conduit to controlthe flow of fluid through the fluid conduit, with the processorcontrolling the fluid control device. In response to the agentconcentration value exceeding the alarm threshold, the processor maycause the fluid control device to stop fluid from flowing through thefluid conduit.

The agent sensor may comprise almost any type of sensor capable ofdetecting agents in a fluid, such as an ultrasonic air detector or anair detector that uses electromagnetic energy, such as light, to detectair in the system. In a preferred embodiment, the agent sensor is an airsensor.

The apparatus may be part of an overall fluid delivery system forintroducing fluid to a patient, including a fluid source, a fluidconduit downstream of and in fluid communication with the fluid source,a cannula in fluid communication with the fluid source and configured tobe introduced into a patient's body to provide fluid thereto, an agentsensor coupled to the fluid conduit for providing signals in response toagent sensed in the fluid conduit, and a processor that receives theagent signals from the agent sensor, determines a weighted agent signalvalue of each agent signal based on the signal and the volume deliveredsince the signal was received, and processes several weighted agentsignal values to determine a primary agent concentration value. Theprimary agent concentration value is compared to an alarm threshold, andan alarm is activated is the threshold is exceeded.

The agent concentration value may be determined by applying a weightingvalue to each agent signal as a separate calculation. The weightingvalue applied to each agent signal value may change based upon the “age”of an agent signal. For example, the weighting value may decrease for“older” (i.e., less recently received) agent signal values. The “age” ofan agent signal may be defined as the volume of fluid that has passedsince that particular agent signal value was received and/or generated.The “age” may also be determined as the actual time that has elapsedsince receipt and/or generation of the agent signal value.

The weighting value may take into account numerous parameters. Forexample, the weighting value may itself be a function of the volume offluid moved in each sample and the size of the volume window.

The agent concentration value may also be determined by applying aweighting factor to a past agent concentration value, thereby applyingthat weighting factor to older agent signal values. In such anembodiment, the older agent signal values will effectively have theweighting factor applied to them more often than more recent signalvalues. If the weighting factor is less than 1, these repeatedapplications of the weighting factor will cause older signal values tohave decreased impact on the agent concentration value.

The invention may further include providing, over a period of timeand/or during infusion of a volume of fluid, a second series of agentsignal values, and determining a secondary agent concentration value. Inone embodiment, the secondary agent concentration value may includeweighting values, which may be the same or different from the weightingvalues used to determine the primary agent concentration value.Alternatively, the secondary agent concentration value may use noweighting values. The secondary agent concentration value can becompared to a secondary threshold, which may be a single bubblethreshold, and an alarm may be activated in response to the secondarythreshold being exceeded by the secondary agent concentration value.

Other features and advantages of the present invention will become moreapparent from the following detailed description of the invention whentaken in conjunction with the accompanying drawings.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a simplified block diagram of a system for detecting agents ina fluid line incorporating the principles of the invention as applied toan intravascular fluid infusion system.

FIG. 2 is a graph depicting weighting values as a function of the age ofvarious air signals.

FIG. 3 is a graph depicting weighting values as a function of the age ofvarious air signals.

FIG. 4 is a simplified flowchart showing a process for determining airconcentration in a fluid line according to one embodiment of theinvention.

FIG. 5 a is a graph depicting a varying weighting value as a function ofthe age of various air signals.

FIG. 5 b is a graph depicting a varying weighting value as a function ofthe age of various air signals.

FIG. 5 c is a graph depicting a constant weighting value as applied tovarious air signals.

FIG. 6 is a simplified flowchart showing a process for determining airconcentration in a fluid line according to a further embodiment of theinvention.

FIG. 7 is a simplified flowchart showing a process for determining airconcentration in a fluid line according to a further embodiment of theinvention.

FIG. 8 is a signal flow diagram depicting the use of weighted past airconcentration values.

FIG. 9 is a simplified block diagram of a system for detecting air in afluid line according to a further embodiment of the invention.

FIG. 10 is a graph depicting a varying weighting value curve as afunction of the age of various air signals.

FIG. 11 is a signal flow diagram of an embodiment where the weightingfactors a and b are varied.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

Referring now to the drawings with more particularity, wherein likereference numerals in the separate views indicate like or correspondingelements, there is shown in FIG. 1 a block diagram of a fluid deliverysystem 10 incorporating aspects of the current invention. The fluiddelivery system includes a fluid source 12 supplying fluid to a patient14 via a fluid conduit 16 and cannula 18. In the embodiment of FIG. 1, aflow control device 20 controls the flow of fluid through the conduit.The flow control device may include a pump motor 22 driving a pumpingmechanism 24, which in the embodiment shown comprises a rotating camshaft 26 coupled to the pump motor 22 and moving a series of peristalticelements 28. The peristaltic elements 28 operate on the conduit 16 tomove fluid from the fluid source 12, through the conduit 16, and intothe patient 14 via the cannula 18.

In the embodiment of FIG. 1, a user input device 30, such as a keypad,provides operator instructions, such as flow rate selection, to aprocessor 32. The processor 32 controls the operation of the pump motor22 driving the pumping mechanism 24. A motor position sensor (not shown)determines the position of the pump motor 22 and pumping mechanism 24,and provides a position signal to the processor 32.

Located along a section 36 of the fluid conduit is a sensor 34 coupledto the conduit 16 to sense agents in that particular fluid conduitsection 36. In the embodiment depicted, the sensor 34 is an air sensorthat detects air in the conduit section 36. An analog-to-digitalconverter 38 (“A-to-D”) receives the output signals from the sensor 34and converts them to a digital format at a particular sample ratecontrolled by the processor 32. The output signals indicate the amountof air in the line at a particular point in time. An age determiner,such as a volume accumulator 40, provides an age value for the outputdigital signals, with the age value a function of the volume that hasbeen introduced through the fluid line. (A clock could also provide anage value based upon the time that the output digital signal isgenerated or received, depending on the particular system.) Theprocessor 32 receives the digital signals, processes them as describedin more detail below, and determines an air concentration valuerepresenting air passing through the fluid delivery system 10. A display42 may present an indication of the air concentration value. One or morealarms 44 are provided to indicate an unsatisfactory air concentrationvalue.

The air signals may be stored in a memory 46, which may also providevarious threshold values to the processor 32. In one embodiment, theprocessor 32 applies a weighting value to each air signal, with theweighting value a function of the age of the output air signal. Notethat age may be determined based on elapsed time or based on the volumeof fluid that has passed since the event occurred. For example, the ageof an output air signal may be determined as the volume of fluid thathas entered the fluid line since the particular air signal was received.

As shown in FIG. 2, where K represents the age of the air signals, inone embodiment the weighting value is largest for the most recent outputair signals, and drops off for older output air signals. (Note that theweighting values shown in FIGS. 2 and 3, including the maximum value of1.0, are for illustrative purposes only.) In the embodiment depicted inFIG. 2, air signals that are older than a cutoff age V_(cutoff) arediscarded, as may occur where a limited number of memory registers areexceeded and older values are displaced by younger values. In theembodiment shown, the age of the air signal is determined as the volumepumped into the IV system, so that the volume window Qwindow is thevolume of fluid pumped into the IV system in the period between thepresent time 0 and the cutoff age V_(cutoff).

FIG. 3 shows another embodiment, but wherein there is no cutoff ageV_(cutoff). Instead, the older output air signals are given weightingsthat approach, but do not actually reach, zero. Note that even thougholder output air signals are not discarded, their weightings eventuallybecome so small as to be negligible, so that a volume window Qwindow canbe an effective representation of the volume of fluid pumped during theperiod in which air signals are given a significant weighting.

In such embodiments, the air concentration value can be determined via aformula such as the following:

$\begin{matrix}{{{AirConcentration}(0)} = {\sum\limits_{K = 0}^{N - 1}\left( {{{AirSignal}(K)} \times b \times a^{K}} \right)}} & (1)\end{matrix}$where AirSignal(0) is the current (i.e., most recent) air signal,AirSignal (1) is the next to the most recent air signal, etc.; N is thetotal number of air signals used to determine the air concentrationvalue; and b and a are weighting factors. If the weighting factor a isless than zero, then “older” airsignal values, such as where K>>0, willbe given progressively less weight due to the shrinking of the valuea^(K) in the above formula. The above equation is only one example ofsuch a formula—numerous other formulae are also well within the scope ofthe invention, so long as the effect is to give differing weights todifferent air signal values. In the embodiment depicted in Equation 1,the weighting factor a (“PastWeight”) is used to vary the air signalweightings according to the age of the air signal value, represented bythe value K, while the application of weighting factor b(“CurrentWeight”) is unaffected by the age of the air signal value.

The weighting factors may be variables that take into accountoperational characteristics of the system, such as fluid flow rate,desired sensitivity, etc, which may vary during pump operation. Forexample, a weighting factor may be a function of various parameters,such as the volume of fluid (Qsample) pumped over the period to whichthe air signal value-corresponds (which may vary depending on pump flowrate and the particular pump steps and/or groups of steps), and thedesired volume of fluid (Qwindow) over which the air signal values aregiven relevant weightings. In one embodiment, the weighting factor a(PastWeight) is a function of Qwindow and Qsample, as follows:

$\begin{matrix}{{{AirConcentration}(0)} = {\sum\limits_{K = 0}^{N - 1}\left( {{{AirSignal}(K)} \times b \times {\mathbb{e}}^{\frac{{- K} \times {Qsample}}{{Qwindow}/3}}} \right)}} & (2)\end{matrix}$Thus the FIG. 5 b current air sample, AirSignal(0), is given a weightingof b (because e⁰=1). The next most recent air sample, AirSignal(1), isweighted by

$\begin{matrix}{\mathbb{e}}^{\frac{- {Qsample}}{{Qwindow}/3}} & (3)\end{matrix}$and so on.Note that Equation 2 is merely one simplified example of such a formula.Other formulae are also within the scope of the invention. For example,the weighting factor b may be a function of Qwindow and Qsample and/orof weighting factor a. For example, with a defined as set forth inEquation 2, the value b could be defined by the formula b=1−a.

In Equation 2, K goes from 0 to N−1, indicating that a number N of airsignals are used to determine the air concentration value. N may be avery large or infinite number, as was depicted in FIG. 3. However, insome circumstances, such as where only a limited number of memoryregisters are available to store individual sir signal values, thenumber N may be much smaller. In practicality, the number of air signalvalues received over an extended period may grow to be quite large,which may require discarding of older air signal values, as depicted inFIG. 2.

One option for dealing with the large number of air signal valuesreceived over a long period is to store them in a memory 46, depicted inFIG. 1, that may include “volume delivered” or time referencesindicating the age of the output air signal values. Newer air signalvalues may be stored, with older values shifted downward on theregister. The oldest air signal values may be discarded as the registersare filled, thus making way for newer values.

FIG. 4 is a simplified flowchart depicting a process for determining airconcentration in a fluid line according to one embodiment of theinvention. After system start 52 (or a reset, such as a user-initiatedmanual reset), step 54 includes receiving a new air signal value, whichis added to the top of the memory register at step 56. Step 56 includesshifting existing air signal values down in the memory register, withthe oldest air signal value being discarded. At step 58, the air signalsare weighted according to their age, to generate weighted air signalvalues. At step 60, the processor adds the weighted air signal valuestogether to determine an air concentration value. At step 62, the airconcentration value is compared to a primary threshold value, also knownas an air density threshold. Where the air concentration value exceedsthe primary threshold, an alarm is sounded (step 64). The system mayalso operate to stop further delivery of fluid through the conduit whenthe air density threshold is exceeded. If the threshold if not exceeded,the system prepares to repeat the cycle. The system then returns to step54 and receives a new air signal value.

In one embodiment, the system continuously updates the calculated airconcentration value. For example, in the embodiment depicted in FIG. 4,each time a new air signal value is received by the processor, thesystem determines a new air concentration value and compares it to aprimary threshold value. If the new air concentration value exceeds theprimary threshold value, an alarm is sounded.

The primary threshold value may be set through a variety of techniques.The primary threshold value may be a single fixed value that ispreprogrammed into the system. The primary threshold value may also beselected by a user. The primary threshold value may vary as a functionof one or more parameters such as the particular fluid, patientcharacteristics (such as weight), or the flow rate through the fluidconduit. The primary threshold may be determined from a formula with oneor more variables, or may be selected from a table of several primarythreshold values.

Comparing the air concentration value to the primary threshold value ishelpful in rapidly detecting excessive air in the fluid conduit whilepreventing false alarms. However, the primary threshold and airconcentration value comparison may not be the most desirable method fordetecting all fluid flow anomalies. For example, where a fluid deliverysystem has had almost no air and suddenly runs out of fluid, a large airpocket will typically be introduced into the system. In such asituation, comparing the air concentration value to primary thresholdvalue will typically cause the alarm to sound prior to a significantamount of air being introduced to the patient, but significant amountsof air may be introduced into the IV system itself (but well upstream ofthe patient) prior to alarm activation. To minimize the amount of airintroduced into the IV system and reduce system downtime, it would bedesirable if the alarm were sounded as rapidly as possible so that anattendant can rapidly refill or replace the fluid supply.

To increase the system's ability to rapidly sound an alarm in varioussituations, the system may include a secondary threshold value to whichis compared a secondary air concentration value. The secondary airconcentration value may be an air concentration value which isdetermined in parallel or in tandem with the primary averagedconcentration value. The secondary air concentration value may bedetermined with a weighting system that is distinct from the weightingsystem used for the primary air concentration value, and may be comparedto a secondary threshold value that is different from the primarythreshold value.

FIG. 5 a depicts a primary weighting value curve 66 a corresponding to arelatively large window volume Qwindow_(primary). Note that the primaryweighting value curve 66 a gives reduced weighting to “older” values.Such a primary weighting value may be used to determine the primary airconcentration value, which will be compared to a primary thresholdvalue. FIG. 5 b depicts a secondary weighting value curve 66 bcorresponding to a smaller window volume Qwindow_(secondary), which maybe used to determine a secondary air concentration value for comparisonto a secondary threshold value. Note that smaller Qwindow valuescorrespond to a shorter period during which the air values are givenrelevant weightings in determining air concentration values.

By having a larger Qwindow value, as shown in FIG. 5 a, the primary airconcentration value may represent the amount of air in the fluidintroduced into the IV system over a relatively long period of timeand/or fluid volume, depending on the flow rate. Such large Qwindowvalues are useful in detecting certain fluid flow anomalies where smallamounts of air are introduced into the system over a long period,possibly building up to an unacceptable level. For example, conditionsmay develop in an IV system where a “train” of very small bubbles isintroduced into the IV system over an extended period. Although theindividual bubbles are very small and may not activate an alarm thatlooks at only a small period of time or volume, such a train of bubblesmay, over a period of time or delivered fluid volume, introduce asignificant amount of air into the system. By using a large Qwindow incombination with a relatively low threshold, the current invention canactivate an alarm when such bubble trains occur.

The use of a large Qwindow with a relatively low threshold is helpful indetecting fluid flow anomalies that involve small amounts of air thatare introduced into the IV system in a large volume of fluid and/or overa long period of time. However, a large Qwindow with a low threshold maynot, by itself, always be the best method for detecting fluid flowanomalies. For example, where a large amount of air is introduced intothe system over a very small fluid volume and/or a short period of time,but with little or no air previously introduced into the system, an airconcentration value calculated with a large Qwindow may not exceed evena small threshold due to the weighting value. However, an airconcentration value calculated under the same circumstances, but using asmaller Qwindow, will typically exceed an even larger threshold. The useof a small Qwindow with a relatively high threshold is thus helpful inrapidly detecting fluid flow anomalies that involve large amounts of airintroduced into the system over a very small fluid volume and/or a shortperiod of time.

The use of a primary air concentration with a large Qwindow and lowthreshold, in combination with a secondary air concentration value witha small Qwindow and a high threshold, allows the system to rapidly andefficiently detect long-term anomalies (e.g., trains of small bubbles)as well as short-term anomalies (e.g., large air bubbles introducedsuddenly into the system). To increase a system's effectiveness inrapidly detecting medium-term anomalies (such as where a moderate amountof air is introduced into the system), a third air concentration value,with a medium-size Qwindow and a medium-size threshold, may be used.Depending on the specific IV system and the desired sensitivity,additional air concentration values may be included (i.e., fourth,fifth, etc. air concentration values), having differing thresholds andQwindows. Note that the various air concentration calculations andthreshold comparisons can be performed in parallel or tandem with eachother.

As discussed above, the secondary air concentration value may bedetermined with a small Qwindow and a relatively high threshold todetect large amounts of air introduced into the system in a short periodof time or in a small volume of fluid. Where Qwindow becomes very small,the weighting value plays less of a role in determining the airconcentration value. For detecting large single bubbles that enter theIV system, such as may occur when the fluid supply reservoir becomesempty, the use of a varying weighting value may not be the mostefficient approach, depending on the characteristics of the particularsystem. FIG. 5 c depicts a constant weighting value 66 c that can beapplied to a select set of air values over a small Qwindow.

In one embodiment of the invention, the secondary air concentrationvalue is determined with a constant weighting value (as depicted in FIG.5 c), and the secondary air concentration value is compared to a singlebubble threshold to detect large single bubbles. As shown in FIG. 6,after the newest air signal value has been added to the register at step56, the processor takes a limited number of the most recent air signalvalues to determine the secondary air concentration value, also known asa single bubble value. The most recent air signal values would typicallybe a subset of the air signal values used to determine the primary airconcentration value. In the embodiment of FIG. 6, the single bubblevalue is determined (at step 68) by merely adding the most recent airsignal values, without the use of any weighting values. At step 70, thesingle bubble value is compared to the single bubble threshold. If thethreshold is exceeded, then the alarm is sounded (step 64). Otherwise,the system repeats the cycle as new air signal values are received.

Storing a large number of air signal values may require a relativelylarge amount of memory registers, which may be undesirable in somecircumstances. Additionally, independently multiplying large numbers ofair signal values by different weighting values can be processorintensive. In one embodiment of the invention, the system uses aweighted past air concentration value, thus reducing the requirementsfor multiplication operations and memory. In such an embodiment thecurrent air concentration value is determined as a function of thecurrent air signal AirSignal(0) and a weighted version of the mostrecently calculated air concentration value (i.e., a weighted past airconcentration value).

In determining the current air concentration value by using a weightedpast air concentration value, a formula such as the following might beused:FilterOut(0)=b×AirSignal(0)+a×FilterOut(1)  (4)where:

AirSignal(0) = the most recent air signal value; FilterOut(0) = thecurrent air concentration value that will be compared with the alarmthreshold; FilterOut(1) = the previously calculated air concentrationvalue; a = a weighting factor (“PastWeight”); and b = a weighting factor(“CurrentWeight”).Note that the value (a×FilterOut(1)) is the weighted past airconcentration value.

The effect of such a formula is that older air signals have a lesserimpaction the current air concentration value FilterOut(0). That is, theolder air signal values are effectively given a lesser weighting. Forexample, using the above-cited formula, the most recent air signal valueAirSignal(0) is given a fraction of its entire value by multiplying itby the weighting factor CurrentWeight (b). AirSignal(1), which had beenused to determine FilterOut(1), would be effectively given a weightingvalue equal to PastWeight×CurrentWeight. AirSignal(2), which had beenused to determine FilterOut(2) and thus also was a factor in calculatingFilterOut(1), would effectively be given a weighting value of(PastWeight)²×CurrentWeight. AirSignal(3) would effectively be given aweighting value of (PastWeight)³×CurrentWeight, etc.

In a preferred embodiment, the weighting factor PastWeight (a) is lessthan 1, so that the older air signal values will be given progressivelyless weight as they age. The air concentration value FilterOut(0) isthus calculated as a function of all of the air signal values, so thatthe number of air signal values that are used to calculated FilterOut(0)is not limited by a set number of memory registers.

FIG. 7 is a simplified flowchart depicting a process whereby the systemuses a weighted past air concentration value instead of individuallymultiplying individual air signal values and weighting values. In theembodiment of FIG. 7, after initial start 72 (or manual reset) of thesystem, an initial FilterOut(1) value, which is below the alarmthreshold, may be provided (at step 74) either as an initial input valueor computed as a function of various factors, such as fluid volume,delivery rate, alarm threshold value, selected sensitivity, etc. As thesystem operates, a current air signal value AirSignal(0) is received (atstep 76). At step 78, the processor determines a new air concentrationvalue FilterOut(0), which is calculated as a function of AirSignal(0)and FilterOut(1). At step 80, the new air concentration valueFilterOut(0) is compared to the primary threshold. If the primarythreshold is exceeded, an alarm sounds (at step 82). If the new airconcentration value is within the threshold limit, the currentFilterOut(0) value becomes FilterOut(1) (at step 84), and the cyclerepeats with receipt of a new air signal value (step 76).

Note that FIG. 7 is a simplified depiction of one embodiment of theinvention. There may be numerous additional steps involved, depending onthe particular embodiment. For example, the primary threshold may beset, either as a directly input value from the user or as a calculatedvalue determined from various parameters such as fluid flow rate,patient characteristics (weight, age, etc.), the type of fluid involved,etc. Moreover, the primary threshold may, as discussed previously, beused in conjunction with additional thresholds to which are comparedadditional air concentration values.

The efficiency of the use of weighted past air concentration values,which is a recursive implementation referred to as an infinite impulseresponse (IIR) method, is shown in FIG. 8, which depicts a signal flowdiagram for an embodiment of such a system. The values AirSignal(0),FilterOut(1), a, and b are used to derive each new FilterOut(0) value.Only one memory register 85 is required, which is used to store theprevious filtered air concentration value FilterOut(1). Because thesystem is “recursive,” i.e., uses past results to compute currentresults, it effectively applies weighting to all air signal values everreceived, which in an IV system may be to the beginning of the infusion.For older air signals, however, the weighting will typically drop soclose to zero as to be largely negligible.

In a further embodiment of the invention, the system uses a combinationof direct weighting of recent air signal values along with a weightedpast air concentration value. For example, as set forth in the followingformula, the invention may apply a first weighting factor to the twomost recent air signal values, which may be stored in memory registers,while a second weighting factor is applied to the most recentlycalculated air concentration value FilterOut(1):

$\begin{matrix}{{{FilterOut}(0)} = {{\left( \frac{Qsample}{{Qsample} + \frac{2 \times {Qwindow}}{3}} \right) \times \left( {{{AirSignal}(0)} + {{AirSignal}(1)}} \right)} - {\left( \frac{{Qsample} - \frac{2 \times {Qwindow}}{3}}{{Qsample} + \frac{2 \times {Qwindow}}{3}} \right) \times {{FilterOut}(1)}}}} & (5)\end{matrix}$where:

AirSignal(0) = the current air signal value; AirSignal(1) = the nextmost recent air signal value; FilterOut(0) = the current airconcentration value that will be compared with the alarm threshold;FilterOut(1) = the most recently calculated air concentration value;Qsample = the volume of fluid moved in the sample; and Qwindow = thesize of the volume window.

In the particular embodiment shown in Equation 5, the weighting factoror multiplier for the current air signal value (AirSignal(0)) andimmediately previous air signal value (AirSignal(1)) is a function ofthe volume of fluid moved in each sample (Qsample) and the size of thevolume window (Qwindow). As the size of the volume window Qwindow isincreased, the weighting factor generally decreases, thereby placingsmaller weight on each individual air signal value. As the sample volumeQsample increases, the weighting generally increases to reflect the factthat the present air signal value is representing a larger volumeincrement.

The currently calculated air concentration value, FilterOut(0), inEquation 5 is thus determined using the immediate past air concentrationvalue FilterOut(n), to which is applied a weighting term which is itselfa function of Qwindow and Qsample. FilterOut(0) is also determined byapplying a weighting factor directly to the two most recent air signalvalues AirSignal(0) and AirSignal(1).

A particular embodiment of the invention is depicted in FIG. 9, in whicha simple sensor 34 a provides a binary signal indicating air or no airin the particular section 36 a of the fluid conduit 16. The sensor 34 atakes a sample each time that the pump mechanism 24 takes a step, sothat the resulting binary air values represent either a step with air ora step without air. A clock sampler 84 provides values indicating towhich pump motor step each binary air value corresponds.

With many peristaltic mechanisms driven by a step motor, the fluid flowvaries widely from step to step, and some steps may even generatenegative flow. Thus, the binary air values for various steps may have tobe processed to account for the fluid that actually flowed during thatstep.

In the embodiment shown, the motor control 86 groups the steps in eachpump cycle into several packets, so that each packet includes severalpump steps. The fluid volume (Qsample) pumped in the particular packetmay be of the same order of magnitude as the fluid volume pumped in theother packets. To achieve this result, the packets may have differentnumbers of step in them. The binary air values are provided to a packetaccumulator 88 and sorted into values representing steps with air andvalues representing steps without air.

When the packet is completed, i.e., when the motor has stepped throughall the steps in the packet, the number of steps with air are divided bythe total number of steps, as shown at 90. The resulting value is an airfraction representing the amount of air introduced into the intravenoussystem during the pump steps of the packet. The air fraction is used, at92, as an air signal value to determine the primary air concentrationvalue. The system also uses a volume window size (Qwindow), which isshown provided by a memory 94, to calculate the primary airconcentration value (FilterOut(0)), such as by using Equation 5 setforth above. The output primary air concentration value is compared, at96, to a primary threshold provided by the memory 94. In the embodimentdepicted, the primary threshold is a Bubble Density Threshold. Theprimary threshold may be selected by the user via an input device 98such as a keyboard or similar control panel, which may also be used toinput commands to the pump motor control 86 such as desired fluid flowrate, etc. The primary threshold may also be determined as a function ofthe selected flow rate, and/or as a function of the window volumeQwindow.

When the primary threshold is exceeded, an alarm 100 is activated. Alarmactivation may also include shutting of the pump motor 24 through thepump motor control 86.

The memory 94 may also provide a secondary threshold value, which asdepicted is a Single Bubble Threshold, to which is compared a secondaryair concentration value. If the secondary threshold value is exceeded,the alarm 100 will be activated.

In the embodiments depicted in FIGS. 2 and 3, the weighting values areapplied to the air signal values so as to cause older air signal valuesto be given decreasing weightings that follow a relatively smooth curvethat gradually and exponentially tapers off. In other embodiments of theinvention, however, weighting values may be used that follownon-exponential curves. For example, a simple linear decay may be used.Moreover, relatively complicated non-exponential curves can be createdby varying the factors a and b. Thus, the “curve” of weighting valuesapplied to air signal values as they age can be tailored as desired tosuit varying circumstances. FIG. 10 depicts an example of such anon-exponential curve 102.

FIG. 11 depicts a signal flow diagram wherein the values a and b arevaried as the air signal values age. A “B” memory register having anumber J of registers stores b values from b₀ to b_(J-1). Similarly, an“A” memory register having a number L of registers stores a values froma₁ to a_(L-1). AirSignal values from the current AirSignal(0) to theoldest AirSignal(L−1) are stored in an air signal memory having a numberJ−1 of registers. Similarly, previous air concentration values, from themost recent (AirConcentration(1)) to the oldest (AirConcentration(L−1)),are stored in an air concentration memory having a number L−1 ofregisters.

As a current air signal value AirSignal(0) is received, it is placed inthe top (current) register in an air signal memory, which has J−1registers, while previous air signal values, AirSignal(1) toAirSignal(L−1), are shifted down in the register. The weighting factorb₀ is applied to AirSignal(0), the factor b₁ is applied to AirSignal(1),etc., with the result used in the calculation of AirConcentration(0).The earlier values of AirConcentration are also used in determining theupdated AirConcentration value. The weighting factor a₁ is applied toAirConcentration(1), the factor a₂ is applied to AirConcentration(2),etc. A desired formula for the final calculation of AirConcentration(0),such as a modified version of Equation 1 discussed above, may beselected to suit particular applications and circumstances. Thus, afinal filtered output value of AirConcentration(0) can be a function ofnumerous past AirSignal values and AirConcentration values, to whichhave been applied many different weighting factors a₁, a₂, . . . , b₁,b₂, . . . .

Although preferred and alternative embodiments of the invention havebeen described and illustrated, the invention is susceptible tomodifications and adaptations within the ability of those skilled in theart and without the exercise of inventive faculty. For example, whilethe examples above have generally been concerned with the use of lightor sound to provide an instantaneous measurement of air in the line,other methods of determining instantaneous measurements of air in theline, such as pressure-sensitive devices, are also compatible with theinvention. Moreover, numerous equations and formula may be used todetermine air concentration values within the scope of the invention. Inaddition to detecting air, the invention may also be applied to thedetection of other agents that might be introduced into a fluid deliverysystem. Thus, it should be understood that various changes in form,detail, and usage of the present invention may be made without departingfrom the spirit and scope of the invention. Accordingly, it is notintended that the invention be limited, except as by the appendedclaims.

1. An apparatus for detecting agents in a fluid delivery system in whichfluid flows through a fluid conduit, the apparatus comprising: an agentsensor coupled to the fluid conduit for providing an agent signal inresponse to an agent sensed in the fluid conduit; and a processor thatis in data communication with the agent sensor and configured to:receive the agent signal from the agent sensor; and determine a currentfiltered agent concentration value by summing: a weighted agent signalvalue comprising a product of the agent signal value and a firstweighting factor, and a weighted filtered agent concentration valuecomprising a product of a past filtered agent concentration value and asecond weighting factor.
 2. The apparatus of claim 1, furthercomprising: a display for providing an indicia of the current filteredagent concentration value.
 3. The apparatus of claim 1, furthercomprising: a fluid control device, said fluid control device acting ona section of the fluid conduit to control the flow of fluid through thefluid conduit.
 4. The apparatus of claim 3, wherein the processorcontrols the fluid control device.
 5. The apparatus of claim 4, whereinthe processor compares the current filtered agent concentration value toan alarm threshold and, in response to the current filtered agentconcentration value exceeding the alarm threshold, causes the fluidcontrol device to stop fluid from flowing through the fluid conduit. 6.A fluid delivery system for introducing fluid to a patient from a fluidsource, the system comprising: a fluid conduit downstream of and influid communication with the fluid source; a cannula in fluidcommunication and downstream of the fluid source and fluid conduit, thecannula configured to be introduced into a patient's body to providefluid thereto; an agent sensor coupled to the fluid conduit forproviding an agent signal in response to an agent sensed in the fluidconduit; and a processor that is in data communication with the agentsensor and configured to: receive the agent signal from the agentsensor; and determine a current filtered agent concentration value bysumming: a weighted agent signal value comprising a product of the agentsignal value and a first weighting factor, and a weighted filtered agentconcentration value comprising a product of a past filtered agentconcentration value and a second weighting factor.
 7. The system ofclaim 6, wherein the processor further compares the current filteredagent concentration value to an alarm threshold and, in response to theagent concentration value exceeding the alarm threshold, provides analarm signal, and wherein the system further comprises: an alarm that isactivated by the alarm signal.
 8. The system of claim 6, furthercomprising: a fluid control device, said fluid control device acting ona section of the fluid conduit to control the flow of fluid through thefluid conduit.
 9. The system of claim 8, wherein the processor controlsthe fluid control device.
 10. The system of claim 9, wherein theprocessor compares the filtered agent concentration value to an alarmthreshold and, in response to the filtered agent concentration valueexceeding the alarm threshold, causes the fluid control device to stopfluid from flowing through the fluid conduit.
 11. A method of detectingagents in a fluid delivery system in which fluid flows through a fluidconduit, the method comprising the steps of: (a) receiving an agentsignal value from an agent sensor, the agent signal value beingindicative of an instantaneous amount of an agent in a fluid conduit;(b) using a processor for computing a current filtered agentconcentration value by summing: a weighted agent signal value comprisinga product of the agent signal value and a first weighting factor, and aweighted filtered agent concentration value comprising a product of apast filtered agent concentration value and a second weighting factor;(c) using a processor for comparing the current filtered agentconcentration value to a threshold value; and (d) causing at least oneof providing an alarm and stopping the flow of fluid in response to thecurrent filtered agent concentration value exceeding the thresholdvalue.
 12. The method of claim 11, wherein the current filtered agentconcentration value is given by b×AirSignal(0)+a×FilterOut(1), where:AirSignal(0) is a current air signal value; FilterOut(1) is a previousfiltered air concentration value; a is a current weighting factor; and bis a past weighting factor.
 13. The method of claim 11, wherein thesecond weighting factor is less than 1.